package com.lyc.struct;

import java.util.Scanner;

public class IfDemo04 {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        System.out.println("请输入一个整数:");
        int age = scanner.nextInt();
        if(age>=18){
            System.out.println("你已成年");
            System.out.println("欢迎进入网吧");
        }else{
            System.out.println("你还未成年");
            System.out.println("请找上级");
        }
        scanner.close();
    }
}
